#! /bin/bash
export LANG=zh_CN.UTF-8
PRESTO_HOME=/export/server/presto/bin/presto


${PRESTO_HOME} --catalog hive --server 192.168.88.80:8090 --execute "

insert into view_consult_dwb.dwb_view_consult
SELECT
a.id,
session_id,
sid,
create_time,
seo_source,
ip,
area,
country,
province,
city,
origin_channel,
from_url,
msg_count,
yearinfo,
monthinfo,
dayinfo,
quarterinfo
from view_consult_dwd.dwd_fact_web_chat_ems a left join view_consult_dwd.dwd_dim_web_chat_text_ems b
on a.id = b.id;

"
